﻿using System;
using System.Collections.Generic;
using System.Text;
using Microsoft.SharePoint;

namespace IKEA.FileExchange.Domain
{
    public static class IKEAFileStoreHelper
    {
        public const string ConfidentialFileListName = "IKEAConfidentialFiles";
        public const string PublicFileListName = "IKEAPub";
        public const string FilePackagesListName = "IKEAFilePackages";
        public const string DownloadTicketsListName = "IKEAFilePackageDownloadTickets";
        public const string DownloadTicketsHistoryListName = "DownloadTicketHistory";

        public static SPList GetFilePackagesList(SPWeb spWeb)
        {
            return spWeb.Lists[FilePackagesListName];
        }

        public static SPDocumentLibrary GetConfidentialFileStore(SPWeb spWeb)
        {
            return (SPDocumentLibrary) spWeb.Lists[ConfidentialFileListName];
        }

        public static SPDocumentLibrary GetPublicFileStore(SPWeb spWeb)
        {
            return (SPDocumentLibrary)spWeb.Lists[PublicFileListName];
        }

        public static SPList GetDownloadTicketsList(SPWeb spWeb)
        {
            return spWeb.Lists[DownloadTicketsListName];
        }

        public static SPList GetDownloadTicketHistoryList(SPWeb spWeb)
        {
            return spWeb.Lists[DownloadTicketsHistoryListName];
        }
    }
}
